﻿create procedure [dbo].[usp_AssemblyUpdate]
	@AssemblyId int
	, @ConcurrencyId rowversion
	, @CodeBase nvarchar(1024)
	, @EntryPoint nvarchar(1024)
	, @FullName nvarchar(512)
	, @GlobalAssemblyCache bit
	, @HostContext bigint
	, @ImageRuntimeVersion nvarchar(100)
	, @Location nvarchar(512)
	, @ManifestModule nvarchar(1024)
	, @ReflectionOnly bit
	, @DebugBuild bit
as

begin try
	
	begin transaction
	
		update [dbo].[Assembly]
		set
			CodeBase = @CodeBase
			, EntryPoint = @EntryPoint
			, FullName = @FullName
			, GlobalAssemblyCache = @GlobalAssemblyCache
			, HostContext = @HostContext
			, ImageRuntimeVersion = @ImageRuntimeVersion
			, Location = @Location
			, ManifestModule = @ManifestModule
			, ReflectionOnly = @ReflectionOnly
			, DebugBuild = @DebugBuild
		where AssemblyId = @AssemblyId and ConcurrencyId = @ConcurrencyId
		
	commit transaction

end try
	
begin catch
	if @@trancount > 0
	begin
		rollback transaction;
	end
	execute [dbo].[usp_SqlErrorInsert]
end catch


